﻿<%@ Page Language="C#" MasterPageFile="~/UI/Main/Main.Master" AutoEventWireup="true"
    CodeBehind="Update_Calendar.aspx.cs" Inherits="OrganizedIN.UI.Calendar.Update_Calendar" %>

<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="server">

    <script type="text/JavaScript">
        function CheckValidation() {
            if (document.getElementById("<%=txtSummary.ClientID%>").value == "") {
                alert("Please Enter Summary.")
                document.getElementById("<%=txtSummary.ClientID%>").focus();
                return false;
            }
            
            var strfilename = document.getElementById("<%=FileUpload1.ClientID%>").value;
            if (strfilename.length > 4) {
                if (strfilename.substring(strfilename.length, strfilename.length - 3) != 'ics') {
                    alert("Please select valid Calendar file (*.ics)")
                    return false;
                }
            }
        }
    </script>

</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" runat="server">
    <div id="middle_tab">
        <div id="middle_tab_title" align="center">
            My Calendar</div>
        <div class="middle_tab_content">
            <br />
            <h4>
                You can Add, Search, Update, Delete, Archive, and Share with your
                Group by clicking on the below icons:</h4>
            <br />
        </div>
        <div id="icon_link_wrapper" align="center">
            <div id="icon_primary_calendar" align="center">
                <a href="Add_New_Calendar.aspx" onmouseout="MM_swapImgRestore()" onmouseover="MM_swapImage('Add New','','../../images/add_02.jpg',1)">
                    <img src="../../images/add_01.jpg" alt="Add New" width="75" height="75" border="0" id="Add New" /></a></div>
            <div id="icon_secondary" align="center">
                <a href="Search_Calendar.aspx" onmouseout="MM_swapImgRestore()" onmouseover="MM_swapImage('Search','','../../images/search_02.jpg',1)">
                    <img src="../../images/search_01.jpg" alt="Search" name="Search" width="75" height="75"
                        border="0" id="Search" /></a></div>
            <div id="icon_secondary" align="center">
                <a href="Update_Calendar.aspx">
                    <img src="../../images/update_02.jpg" alt="Update" name="Update" width="75" height="75"
                        border="0" id="Update" /></a></div>
            <div id="icon_secondary" align="center">
                <a href="Share_Calendar.aspx" onmouseout="MM_swapImgRestore()" onmouseover="MM_swapImage('Share with group','','../../images/share_02.jpg',1)">
                    <img src="../../images/share_01.jpg" alt="Share with group" name="Share with group"
                        width="75" height="75" border="0" id="Share with group" /></a></div>
            <div id="icon_secondary" align="center">
                <a href="Archive_Calendar.aspx" onmouseout="MM_swapImgRestore()" onmouseover="MM_swapImage('Archive','','../../images/archive_02.jpg',1)">
                    <img src="../../images/archive_01.jpg" alt="Archive" name="Archive" width="75" height="75"
                        border="0" id="Archive" /></a></div>
        </div>
        <br />
        <br />
        <div class="documents_table">
            <table width="97%" border="0" cellspacing="1" cellpadding="5" align="center">
                <tr bgcolor="#d8e1f3">
                    <td colspan="3" align="left">
                        <h4>
                            <strong>
                                <asp:Label ID="lblTodayDate" runat="server" Text=""></asp:Label>
                                (Today)</strong> ▪ <a href="#"><strong>ReDate</strong></a></h4>
                    </td>
                </tr>
                <tr bgcolor="#d8e1f3">
                    <td colspan="3" align="left" style="color: #FF0000">
                        <h4>
                            <strong>
                                <asp:Label ID="lblErrMsg" runat="server" Text=""></asp:Label></strong></h4>
                    </td>
                </tr>
                <tr bgcolor="#d8e1f3">
                    <td width="20%" align="right" class="middle_text3">
                        Calendar Summary:
                    </td>
                    <td colspan="2" align="left">
                        <asp:TextBox ID="txtSummary" runat="server"></asp:TextBox>
                    </td>
                </tr>
                <tr bgcolor="#d8e1f3">
                    <td align="right" class="middle_text3">
                        Updated Calendar file:
                    </td>
                    <td colspan="2" width="80%" align="left">
                        <asp:Label ID="lblFilename" runat="server" /><br />
                        <asp:FileUpload ID="FileUpload1" runat="server" />
                        &nbsp;
                        <asp:Button ID="btnImport" runat="server" Text="Import**" Visible="false" />
                    </td>
                </tr>
                <tr bgcolor="#d8e1f3">
                    <td align="right" class="middle_text3">
                        Calendar Import Type :
                    </td>
                    <td colspan="2" width="80%" align="left">
                        <asp:DropDownList ID="ddlImportType" runat="server">
                            <asp:ListItem Text="Outlook" Value="Outlook" Selected="True" />
                            <asp:ListItem Text="Gmail" Value="Gmail" />
                        </asp:DropDownList>
                    </td>
                </tr>
                <tr bgcolor="#d8e1f3">
                    <td align="right" valign="top" class="middle_text3">
                        Share:
                    </td>
                    <td colspan="2" align="left">
                        <asp:TextBox ID="txtshare" runat="server"></asp:TextBox>
                    </td>
                </tr>
                <tr bgcolor="#d8e1f3">
                    <td align="right" class="middle_text3">
                        &nbsp;
                    </td>
                    <td colspan="2" align="left">
                        <a href="#" class="save_button">
                            <asp:Button ID="save_button" runat="server" Enabled="false" OnClick="save_button_Click" Text="Save"
                                Width="75px" />
                        </a>
                    </td>
                </tr>
                <tr bgcolor="#d8e1f3">
                    <td colspan="3" align="right" class="middle_text3">
                        &nbsp;
                    </td>
                </tr>
            </table>
        </div>
        <br />
    </div>
</asp:Content>
